<?php

use Illuminate\Routing\Router;

Route::group([
    'prefix' => 'admin/totem',
    'namespace' => 'Frieza\\Modules\\Totem\\Controllers',
    'middleware' => [
        'web',
        'admin'
    ],
], function (Router $router) {
    $router->get('/index', 'IndexController@index');
    $router->get('/create', 'IndexController@create');
    $router->post('/save', 'IndexController@save');
    $router->get('/group','IndexController@group')->name('totem.group');
    $router->get('/index/{id}/edit','IndexController@edit');
    $router->get('/type_list', 'TotemTypeController@typeList');
    $router->get('/type_create', 'TotemTypeController@typeCreate');
    $router->get('/type_list/{id}/edit', 'TotemTypeController@typeCreate');
    $router->post('/type_save', 'TotemTypeController@typeSave');
    $router->get('/config_list', 'TotemConfigController@list');
    $router->get('/config_create', 'TotemConfigController@create');
    $router->get('/config_list/{id}/edit', 'TotemConfigController@create');
    $router->post('/config_save', 'TotemConfigController@save');
    $router->put('/config_list/{id}', 'TotemConfigController@edit');
});
